import { CheckError, ICheck, check, checkError } from "../src/check"

@check("Test","测试组件")
export class Test implements ICheck{
    name:string
    test2 = new Test2("测试1里的2")
    constructor(name:string){
        this.name = name;
    }
    __check__(check:CheckError) {
        this.test2.__check__();
        check.emit("算错了哦")
        return this.name;
    }

}
@check("Test2","测试2")
export class Test2 implements ICheck{
    name:string
    constructor(name:string){
        this.name = name;
    }
    __check__(check?: any) {
        check.emit("又错了1")
        check.emit("又错了2")
        return this.name;
    }
}